/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package se.sll.service.catalogue.idmap.entity;

import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;
import lombok.AccessLevel;
import lombok.Data;
import lombok.Getter;
import lombok.Setter;

/**
 *
 * @author khaleddaham
 */
@SuppressWarnings("PMD.UnusedPrivateField")
@Entity
@Data
@Table(name = "skl", uniqueConstraints = {
    @UniqueConstraint(columnNames = {"sklId"})})
public class SKLEntity {

    @Id
    @GeneratedValue(strategy=GenerationType.AUTO)
    @Getter(AccessLevel.NONE)
    @Setter(AccessLevel.NONE)
    private Long id;
    
    private String sklId;
    
    @OneToMany(fetch=FetchType.LAZY, cascade = CascadeType.MERGE)
    private List<HSAEntity> hsaId;
    
    private boolean export;
}